<?php
ini_set("memory_limit", "64M");
require_once realpath(dirname(__FILE__).'/../../app/init.php');
require_once 'AIR2_DBManager.php';
AIR2_DBManager::init();

/**
 * Load tags separate from base fixtures, for memory usage reasons
 */

$conn = AIR2_DBManager::get_master_connection();

try {
    $conn->execute('SET FOREIGN_KEY_CHECKS = 0');

    echo " > loading tag fixtures .... ";
    Doctrine::loadData(APPPATH.'/fixtures/tags');
    echo "Done!\n";

    $conn->execute('SET FOREIGN_KEY_CHECKS = 1');
} catch (Doctrine_Exception $e) {
    error_log("Error loading tag fixture file!");
    error_log($e->getMessage());
}

?>
